Technical Q&A QD01
 PPDs


Q: I know where the PPDs are located (System Folder:Extensions:Printer Descriptions), but how can I know what file reflects the current printer?

A: To find the PPD associated with the current printer, you should use the PrGeneral call with the PSPrimaryPPDOp opcode as documented in the LaserWriter 8 API. Full documentation can be found on the Toolchest CD in the Developer CD series.

The relevant portions of the header file follow:

enum {		/* new PrGeneral selectors */
	getPSInfoOp = 10,
	PSIntentionsOp = 11,
	PSAdobeOp = 14,
	PSPrimaryPPDOp = 15
};
struct TPSPrimaryPPD{
	short	iOpCode;
	short	iError;
	long	lReserved;
	short	ppdIsRealFile;
	FFSpec	ppdFile;
};
typedef struct TPSPrimaryPPD TPSPrimaryPPD;

[May 01 1995]


Developer Documentation | Technical Notes | Development Kits | Sample Code